﻿// Original author contact info: Owen Emlen (owene_1998@yahoo.com)
// Note: other individuals may also have contributed to this code
// Project hosted on CodePlex.com as of 1/10/2009 at http://www.codeplex.com/EmlenMud
using System.Runtime.Serialization;
using System;
using System.Xml.Serialization;
using System.Threading;
using System.Reflection;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BrainTechLLC.ThreadSafeObjects;

namespace BrainTechLLC
{
	public class Command : ICommandInfo
	{
        [NonSerialized, XmlIgnore]
        public static List<string> BaseWords = new List<string>();

        public virtual string HelpText { get { return string.Empty; } }
        public virtual string Example { get { return string.Empty; } }

        public virtual List<string> FirstWords { get { return BaseWords; } }

		public virtual bool CheckIsValid(IGameThing source, string first, string input)
		{
			return true;
		}

        public virtual CommandToPerform CreateCommand(IGameThing source, string first, string input)
        {
            return new CommandToPerform(source.AssociatedID, input) { PerformInfo = this.GetType().Name + ".PerformMethod" };
        }
	}
}
